Conditions | 2 |
Total Lines | 12 |
Code Lines | 12 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | import { |
||
29 | |||
30 | @Delete(':id') |
||
31 | @Roles(UserRole.PHOTOGRAPHER) |
||
32 | @ApiOperation({ summary: 'Remove user' }) |
||
33 | public async index( |
||
34 | @Param() { id }: IdDTO, |
||
35 | @LoggedUser() user: UserAuthView |
||
36 | ) { |
||
37 | try { |
||
38 | await this.commandBus.execute(new RemoveUserCommand(id, user.id)); |
||
39 | } catch (e) { |
||
40 | throw new BadRequestException(e.message); |
||
41 | } |
||
44 |